import { NgModule, CUSTOM_ELEMENTS_SCHEMA  }           from '@angular/core';
import { BrowserModule }      from '@angular/platform-browser';
import { RouterModule }       from '@angular/router';
import { HttpModule, Http }   from '@angular/http';
import { PathLocationStrategy, LocationStrategy, HashLocationStrategy } from '@angular/common';
import { HttpClientModule }   from '@angular/common/http';
import { FormsModule }        from '@angular/forms';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
import { ChartsModule }       from  'ng2-charts/ng2-charts';
import { Service}             from './server/server';
import { CudTableService }    from './public/serve/cud-table/cud-table.service';
import { RemoveTableService } from './public/serve/remove-table/remove-table.service';
//import { MessageService }     from './public/serve/message/message.service';
import { TreeService }        from './public/serve/tree/tree.service';
import { PaginationModule }   from 'ngx-bootstrap/pagination';
import { AppComponent }       from './app.component';
import { AppRoutingModule }   from '../app/app.router.module.';
import { CoreModule }         from './core/core.module';
import { PublicModule }       from './public/public.module';
import { SidebarModule }      from './sidebar/sidebar.module';
import { UserModule }         from './user/user.module';
import { HomeModule }         from './home/home.module';
import { SystemModule }       from './system/system.module';
import { TreeComponent }      from './public/tree/tree.component';
import { AppService }         from './app.service';
import { HeaderService }      from './core/services/header.service';
import { InitService }        from './public/serve/init/init.service';
import { HintsService }       from './public/serve/hints/hints.service';
import { SelectionService }   from './public/serve/tree/selection.service';
import { } from 'rxjs';

import {MatButtonModule,MatInputModule} from '@angular/material';

import { DatePipe } from '@angular/common';
import { NgbModule } from '@ng-bootstrap/ng-bootstrap';

//产品标引任务
import { ProductModule} from './product/product.module';
//内文标引任务
import { InternalModule } from './internal/internal.module';
//主题词管理
import { KeywordModule } from './keyword/keyword.module';
//同义词管理
import { SynonymModule } from './synonym/synonym.module';
//内容管理
import { ContentModule } from './content/content.module';
//报表统计
import { ReportModule } from './report/report.module';

import {MessageService} from 'primeng/api';

@NgModule({
  declarations: [
    AppComponent,
  ],
  imports: [
    BrowserModule,
    FormsModule,
    CoreModule,
    SidebarModule,
    RouterModule,
    MatButtonModule,
    MatInputModule,
    AppRoutingModule,
    BrowserAnimationsModule,
    UserModule,
    HomeModule,
    SystemModule,
    HttpModule,
    HttpClientModule,
    PaginationModule.forRoot(),
    NgbModule.forRoot(),
    PublicModule,
    ChartsModule,
    ProductModule,
    InternalModule,
    KeywordModule,
    SynonymModule,
    ContentModule,
    ReportModule
  ],
  exports:[
    BrowserModule,
    FormsModule,
    CoreModule,
    SidebarModule,
    RouterModule,
    AppRoutingModule,
    UserModule,
    HomeModule,
    SystemModule,
    HttpModule,
    HttpClientModule,
    PublicModule
  ],

  providers: [
    Service, 
    RemoveTableService, 
    CudTableService, 
    TreeService, 
    MessageService, 
    HeaderService, 
    InitService, 
    HintsService, 
    SelectionService,
    DatePipe,
    {
      provide: LocationStrategy, 
      useClass: HashLocationStrategy
    }
  ],
  bootstrap: [AppComponent],
  schemas: [ CUSTOM_ELEMENTS_SCHEMA ]
})
export class AppModule { }
